﻿import request from '/@/utils/request';
enum Api {
  AddBusCartGoods = '/api/busCartGoods/add',
  DeleteBusCartGoods = '/api/busCartGoods/delete',
  UpdateBusCartGoods = '/api/busCartGoods/update',
  PageBusCartGoods = '/api/busCartGoods/page',
  GetBusCartDropdown = '/api/busCartGoods/BusCartDropdown',
  GetBusGoodsDropdown = '/api/busCartGoods/BusGoodsDropdown',
  GetSysUserDropdown = '/api/busCartGoods/SysUserDropdown',
}

// 增加我的购物车
export const addBusCartGoods = (params?: any) =>
	request({
		url: Api.AddBusCartGoods,
		method: 'post',
		data: params,
	});

// 删除我的购物车
export const deleteBusCartGoods = (params?: any) => 
	request({
			url: Api.DeleteBusCartGoods,
			method: 'post',
			data: params,
		});

// 编辑我的购物车
export const updateBusCartGoods = (params?: any) => 
	request({
			url: Api.UpdateBusCartGoods,
			method: 'post',
			data: params,
		});

// 分页查询我的购物车
export const pageBusCartGoods = (params?: any) => 
	request({
			url: Api.PageBusCartGoods,
			method: 'post',
			data: params,
		});

export const getBusCartDropdown = () =>
		request({
		url: Api.GetBusCartDropdown,
		method: 'get'
		});
export const getBusGoodsDropdown = () =>
		request({
		url: Api.GetBusGoodsDropdown,
		method: 'get'
		});
export const getSysUserDropdown = () =>
		request({
		url: Api.GetSysUserDropdown,
		method: 'get'
		});

